package wk.coral.jar.config;

import org.springframework.beans.BeansException;
import org.springframework.context.ApplicationContext;
import org.springframework.context.ApplicationContextAware;
import org.springframework.context.annotation.ComponentScan;
import wk.coral.util.applicationContext.ApplicationContextUtil;

/**
 * description: spring IOC config
 * date 2021-01-16 14:40
 *
 * @author Administrator
 * @version 1.0
 */

@ComponentScan("wk.coral")
public class ApplicationContextConfig implements ApplicationContextAware {

    /**
     * initial springContext
     * @param applicationContext
     * @throws BeansException
     */
    public void setApplicationContext(ApplicationContext applicationContext) throws BeansException {
        ApplicationContextUtil.setContext(applicationContext);
    }
}
